<?php

/**
 * @package examples
 */

require 'Zend/Log.php';
require 'Zend/Debug.php';
require 'Zend/Log/Writer/Stream.php';

$log    = new Zend_log();

$writer = new Zend_Log_Writer_Stream("logs/logfile");

$log->addWriter($writer);
try {
    $obj->method();
} catch (Exception $e) {
   $log->log($e, Zend_Log::INFO); 
   // enregistrement de l'état de l'objet
   $log->log(Zend_Debug::dump($obj, null, false), Zend_Log::INFO); 
}